package cn.itcast.day04.demo01;

public class Test1 {
    public static void main(String[] args) {
        String a = "abc";
        String b = "abc";
        String c = b;
        String d = new String("abc");
        System.out.println("a == b is :" + (a == b));
        System.out.println("a == c is :" + (a == c));
        System.out.println("a == d is :" + (a == d));
        System.out.println("b == c is :" + (b == c));
        System.out.println("c == d is :" + (c == d));
        System.out.println("a.equals(b) is :" + a.equals(b));
        System.out.println("a.equals(c) is :" + a.equals(c));
        System.out.println("a.equals(d) is :" + a.equals(d));
        System.out.println("c.equals(d) is :" + c.equals(d));

    }
}
